<include file="public@header"/>
<link href="__TMPL__/public/assets/simpleboot3/css/main.css" rel="stylesheet">

<hook name="admin_before_head_end"/>
<style>
	body{
		background: #f3f3f4;
		font-family: "open sans","Helvetica Neue",Helvetica,Arial,sans-serif;
		    font-size: 13px;
	}
	h1{
		font-weight: 400 !important;
	}
	.main-box-right{
		border-radius: 0 !important;
		width: 97% !important;
	}
</style>
</head>
<body>
<div class="wrapper wrapper-content">
	<div class="row">
		<div class="col-sm-3 ui-sortable">
		    <div class="ibox float-e-margins">
		        <div class="ibox-title">
		            <span class="label label-danger pull-right"></span>
		            <h5>今日上传</h5>
		        </div>
		        <div class="ibox-content">
		            <h1 class="no-margins">{$super_day}</h1>
		            <small>今日上传</small>
		        </div>
		     </div>
		 </div>
		<div class="col-sm-3 ui-sortable">
		     <div class="ibox float-e-margins">
		         <div class="ibox-title">
		             <span class="label label-danger pull-right"></span>
		             <h5>今日安裝</h5>
		         </div>
		         <div class="ibox-content">
		             <h1 class="no-margins">{$superdow_day}</h1>
		             <small>今日安裝</small>
		         </div>
		      </div>
		  </div>
		<div class="col-sm-3 ui-sortable">
		      <div class="ibox float-e-margins">
		          <div class="ibox-title">
		              <span class="label label-danger pull-right"></span>
		              <h5>今日充值</h5>
		          </div>
		          <div class="ibox-content">
		              <h1 class="no-margins">{$new.day_coin}</h1>
		              <small>今日充值</small>
		          </div>
		       </div>
		   </div>
		<div class="col-sm-3 ui-sortable">
		    <div class="ibox float-e-margins">
		        <div class="ibox-title">
		            <span class="label label-danger pull-right"></span>
		            <h5>今日注册</h5>
		        </div>
		        <div class="ibox-content">
		            <h1 class="no-margins">{$new.day_user}</h1>
		            <small>今日注册</small>
		        </div>
		    </div>
		</div>
		<div class="col-sm-3 ui-sortable">
		    <div class="ibox float-e-margins">
		        <div class="ibox-title">
		            <span class="label label-danger pull-right"></span>
		            <h5>全部上传</h5>
		        </div>
		        <div class="ibox-content">
		            <h1 class="no-margins">{$new.posted}</h1>
		            <small>全部上传</small>
		        </div>
		    </div>
		</div>
		<div class="col-sm-3 ui-sortable">
		    <div class="ibox float-e-margins">
		        <div class="ibox-title">
		            <span class="label label-danger pull-right"></span>
		            <h5>全部安装</h5>
		        </div>
		        <div class="ibox-content" style="height:87px;">
		            <div style="width:33%;float:left;">
						<h1 class="no-margins">{$superdow}</h1>
						<small>全部安装</small>
					</div>
					<div style="width:33%;float:left;">
						<h1 class="no-margins">{$cert_num}</h1>
						<small>剩余安装</small>
					</div>
					<div style="width:33%;float:left;">
						<h1 class="no-margins">{$user_down}</h1>
						<small>用户剩余</small>
					</div>
		        </div>
		    </div>
		</div>
		<div class="col-sm-3 ui-sortable">
		    <div class="ibox float-e-margins">
		        <div class="ibox-title">
		            <span class="label label-danger pull-right"></span>
		            <h5>全部充值</h5>
		        </div>
		        <div class="ibox-content">
		            <h1 class="no-margins">{$new.coin}</h1>
		            <small>全部充值</small>
		        </div>
		    </div>
		</div>
		<div class="col-sm-3 ui-sortable">
		    <div class="ibox float-e-margins">
		        <div class="ibox-title">
		            <span class="label label-danger pull-right"></span>
		            <h5>全部注册</h5>
		        </div>
		        <div class="ibox-content">
		            <h1 class="no-margins">{$new.user}</h1>
		            <small>全部注册</small>
		        </div>
		    </div>
		</div>
	</div>
</div>

    <div class="main-box-right">
        <div id="chart-composite-2">

        </div>
    </div>


    <div class="main-box-right">
        <div id="chart-composite-3">

        </div>
    </div>


    <div class="main-box-right">
        <div id="chart-composite-4">

        </div>
    </div>



<script src="__STATIC__/js/admin.js"></script>
<script src="https://unpkg.com/frappe-charts@1.0.0/dist/frappe-charts.min.iife.js"></script>
<hook name="admin_before_body_end"/>
</body>
</html>

<script type="text/javascript">
    var reportCountList2 = {$superdow_week};
    var reportCountList3 = {$coin_week};
    var reportCountList4 = {$user_week};

  
    var lineCompositeData2 = {
		 labels: {$week},
        datasets: [{
            "name": "Events",
            "values": reportCountList2
        }]
    };

    var lineCompositeData3 = {
        labels: {$week},
        datasets: [{
            "name": "Events",
            "values": reportCountList3
        }]
    };

    var lineCompositeData4 = {
        labels: {$week},
        datasets: [{
            "name": "Events",
            "values": reportCountList4
        }]
    };



    var c2 = document.querySelector("#chart-composite-2");
    var c3 = document.querySelector("#chart-composite-3");
    var c4 = document.querySelector("#chart-composite-4");



    var lineCompositeChart = new Chart (c2, {
        title: "超级签名一周安装",
        data: lineCompositeData2,
        type: 'line',
        height: 130,
        colors: ['#ffa3ef'],
      
    });

    var lineCompositeChart = new Chart (c3, {
        title: "一周充值",
        data: lineCompositeData3,
        type: 'line',
        height: 130,
        colors: ['#3886D4'],
      
    });

    var lineCompositeChart = new Chart (c4, {
        title: "一周注册",
        data: lineCompositeData4,
        type: 'line',
        height: 130,
        colors: ['#64D57C'],
    });
</script>